package _04mybatis.mapper;

import _04mybatis.pojo.User;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;

import java.util.List;

@Mapper
public interface IUserMapper {
    @Insert("insert into user (id,username,password,nickname,created) values(#{id},#{username},#{password},#{nickname},#{created})")
    int insert(User user);
    @Select("select * from user")
    List<User> findById();
}
